package com.unknow.first.geetest.feign;

import com.unknow.first.geetest.vo.GeetestQueryParamVO;
import com.unknow.first.geetest.vo.GeetestValidateResultVO;
import org.cloud.feign.config.FeignTracerConfiguration;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.context.annotation.Lazy;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@Lazy
@FeignClient(name = "${spring.application.group:}COMMON-SERVICE", contextId = "geetestOnCommonService", configuration = {
    FeignTracerConfiguration.class})  // 不区分大小写
public interface GeetestFeignClient {

    @PostMapping(value = "/inner/geetest/verify", consumes = MediaType.APPLICATION_JSON_VALUE)
    GeetestValidateResultVO geetestVerify(@RequestBody GeetestQueryParamVO requestParams);

}
